﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="StuInfo.aspx.cs" Inherits="Test_Stu.StuInfo" %>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
        <div>           
        <a href="StuInfoAdd.aspx">添加</a>
            <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False"  DataKeyNames="Id" AllowSorting="True" OnRowDeleting="GridView1_RowDeleting"><%--AutoGenerateColumns:是否自动生成字段--%>
                <Columns>
                    <asp:BoundField DataField="Id" HeaderText="编号" />
                    <asp:BoundField DataField="Name" HeaderText="姓名" />
                    <asp:BoundField DataField="content" HeaderText="备注" />
                    <asp:BoundField DataField="Cid" HeaderText="班级" />
                    <asp:HyperLinkField HeaderText="详情" Text="详情"  DataNavigateUrlFields="Id" DataNavigateUrlFormatString="StuInfoDetial.aspx?id={0}"/>
                    <asp:HyperLinkField HeaderText="修改" Text="修改"  DataNavigateUrlFields="Id" DataNavigateUrlFormatString="StuInfoUpdate.aspx?id={0}"/>
                    <asp:CommandField ShowDeleteButton="True" />
                </Columns>
            </asp:GridView>   
        </div>
    </form>
</body>
</html>
